#! /bin/csh -f

# Check to see if the MC enviornment variables are set up correctly
if ( $?MCDIR && $?MCENVDIR && $?MCLIBDIR ) then
	else
	cat << EOF
	One or more of the MC Unix enviornment variables--
		MCDIR
		MCENVDIR
		MCLIBDIR
	are not set up.  You can initialize your Unix environment with
	either of the following:
		<MC install path>/localadm/setup.csh
		<MC install path>/localadm/setup.sh

EOF
	exit 1
endif

# Get tech lib
echo ""
echo -n "Please input target technology lib: "
set tech_lib = $<
mcenv dp_tech_lib $tech_lib
if ($status) then
	echo Your technology library does not appear to be set up
	echo Please set up your technology library and restart
	exit 1
endif

# Set up demodir
rm -rf demodir
mkdir demodir
cp src/*.mcl src/mc.env src/*.iter demodir
chmod +w demodir/*.mcl demodir/mc.env demodir/*.iter
cd demodir
mc -tech $tech_lib &
cd ..

# launch pdf
acroread doc/*.pdf &

#Rev $Id: run_demo,v 1.4 1998/07/27 18:56:49 gil Exp $
